﻿<%@ Page Language="C#" MasterPageFile="~/Views/Shared/Site.Master" Inherits="System.Web.Mvc.ViewPage<Sinbiota.Web.Models.ErrorModel>" %>
<%@ Import Namespace="Localization" %>
<%@ Import Namespace="System.Web.Configuration" %>

<asp:Content ID="errorTitle" ContentPlaceHolderID="TitleContent" runat="server">
    <%: Messages.ErrorProcessingOperation%> 
</asp:Content>

<asp:Content ID="errorContent" ContentPlaceHolderID="MainContent" runat="server">
    <h2><%: Messages.ErrorProcessingOperation%></h2>

    
    <div class="display-field"><%= Model.FriendlyMessage %>. ( <span class="monospace"><%: Model.ErrorMessage %> )</span></div>

    <p><%: Messages.ErrorTryAgainOrSupport %> <a href="mailto:<%: WebConfigurationManager.AppSettings["TechSupportEmail"]%>"><%: WebConfigurationManager.AppSettings["TechSupportEmail"]%></a>.</p>
    
    <% if (Model.IsAdmin){ %>
    <div class="display-label"><%: Strings.Message %>:</div>
    <%= Model.ErrorMessage %>
    
    <div class="display-label">Stack:</div>
    <ul class="monospace"><li><%= Model.Exception.StackTrace.Replace("\n","</li><li>") %></li></ul>
    <%} %>
    <a href="javascript: history.go(-1)" class="radius small button"><%: Strings.GoBack %></a>
</asp:Content>
